package com.itheima.a02oopextendsdemo02;

/***
 *@title Test02
 *@description <TODO description class purpose>
 *@author 12468
 *@version 1.0.0
 *@create 2024/10/18 23:22
 **/
public class Test02 {
    public static void main(String[] args) {
        Zi zi = new Zi();
        zi.isShow();
    }
}

class Fu1 {
    String name = "Fu";
    String hobby = "喝茶";
}

class Zi extends Fu1 {
    String name = "Zi";
    String hobby = "吃鸡";

    public void isShow() {
        // 打印zi
        System.out.println(name);
        // 打印fu
        System.out.println(super.name);
        // 打印喝茶
        System.out.println(super.hobby);
        // 打印吃鸡
        System.out.println(hobby);
    }
}
